package cn.dglydrpy.study.ssm.dao.entity;

import java.io.Serializable;

public class Dept implements Serializable {
	
	private static final long serialVersionUID = -1037418843898736286L;
	
	private Integer id;
	private String dept_name;
	private String dept_loc;
	
	public Integer getId() {
		return id;
	}
	public void setId(Integer id) {
		this.id = id;
	}
	public String getDept_name() {
		return dept_name;
	}
	public void setDept_name(String dept_name) {
		this.dept_name = dept_name;
	}
	public String getDept_loc() {
		return dept_loc;
	}
	public void setDept_loc(String dept_loc) {
		this.dept_loc = dept_loc;
	}
	@Override
	public String toString() {
		return "Dept [id=" + id + ", dept_name=" + dept_name + ", dept_loc=" + dept_loc + "]";
	}
	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + ((dept_loc == null) ? 0 : dept_loc.hashCode());
		result = prime * result + ((dept_name == null) ? 0 : dept_name.hashCode());
		result = prime * result + ((id == null) ? 0 : id.hashCode());
		return result;
	}
	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		Dept other = (Dept) obj;
		if (dept_loc == null) {
			if (other.dept_loc != null)
				return false;
		} else if (!dept_loc.equals(other.dept_loc))
			return false;
		if (dept_name == null) {
			if (other.dept_name != null)
				return false;
		} else if (!dept_name.equals(other.dept_name))
			return false;
		if (id == null) {
			if (other.id != null)
				return false;
		} else if (!id.equals(other.id))
			return false;
		return true;
	}
}
